Optimal. Leaf size=105 \[ -\frac{a^2 \sqrt{b} \tan ^{-1}\left (\frac{\sqrt{b} \tan (e+f x)}{\sqrt{a+b}}\right )}{f (a+b)^{7/2}}-\frac{a^2 \cot (e+f x)}{f (a+b)^3}-\frac{\cot ^5(e+f x)}{5 f (a+b)}-\frac{(2 a+b) \cot ^3(e+f x)}{3 f (a+b)^2} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.139397, antiderivative size = 105, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 3, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.13, Rules used = {4132, 461, 205} \[ -\frac{a^2 \sqrt{b} \tan ^{-1}\left (\frac{\sqrt{b} \tan (e+f x)}{\sqrt{a+b}}\right )}{f (a+b)^{7/2}}-\frac{a^2 \cot (e+f x)}{f (a+b)^3}-\frac{\cot ^5(e+f x)}{5 f (a+b)}-\frac{(2 a+b) \cot ^3(e+f x)}{3 f (a+b)^2} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4132
Rule 461
Rule 205
Rubi steps
\begin{align*} \int \frac{\csc ^6(e+f x)}{a+b \sec ^2(e+f x)} \, dx &=\frac{\operatorname{Subst}\left (\int \frac{\left (1+x^2\right )^2}{x^6 \left (a+b+b x^2\right )} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac{\operatorname{Subst}\left (\int \left (\frac{1}{(a+b) x^6}+\frac{2 a+b}{(a+b)^2 x^4}+\frac{a^2}{(a+b)^3 x^2}-\frac{a^2 b}{(a+b)^3 \left (a+b+b x^2\right )}\right ) \, dx,x,\tan (e+f x)\right )}{f}\\ &=-\frac{a^2 \cot (e+f x)}{(a+b)^3 f}-\frac{(2 a+b) \cot ^3(e+f x)}{3 (a+b)^2 f}-\frac{\cot ^5(e+f x)}{5 (a+b) f}-\frac{\left (a^2 b\right ) \operatorname{Subst}\left (\int \frac{1}{a+b+b x^2} \, dx,x,\tan (e+f x)\right )}{(a+b)^3 f}\\ &=-\frac{a^2 \sqrt{b} \tan ^{-1}\left (\frac{\sqrt{b} \tan (e+f x)}{\sqrt{a+b}}\right )}{(a+b)^{7/2} f}-\frac{a^2 \cot (e+f x)}{(a+b)^3 f}-\frac{(2 a+b) \cot ^3(e+f x)}{3 (a+b)^2 f}-\frac{\cot ^5(e+f x)}{5 (a+b) f}\\ \end{align*}
Mathematica [C] time = 1.82896, size = 318, normalized size = 3.03 \[ \frac{\sec ^2(e+f x) (a \cos (2 (e+f x))+a+2 b) \left (\sqrt{a+b} \csc (e) \sqrt{b (\cos (e)-i \sin (e))^4} \csc ^5(e+f x) \left (10 \left (8 a^2+b^2\right ) \sin (f x)-40 a^2 \sin (2 e+3 f x)+8 a^2 \sin (4 e+5 f x)+30 a b \sin (2 e+3 f x)+15 a b \sin (4 e+3 f x)-9 a b \sin (4 e+5 f x)-30 b (3 a+b) \sin (2 e+f x)+10 b^2 \sin (2 e+3 f x)-2 b^2 \sin (4 e+5 f x)\right )+240 a^2 b (\cos (2 e)-i \sin (2 e)) \tan ^{-1}\left (\frac{(\cos (2 e)-i \sin (2 e)) \sec (f x) (a \sin (2 e+f x)-(a+2 b) \sin (f x))}{2 \sqrt{a+b} \sqrt{b (\cos (e)-i \sin (e))^4}}\right )\right )}{480 f (a+b)^{7/2} \sqrt{b (\cos (e)-i \sin (e))^4} \left (a+b \sec ^2(e+f x)\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.115, size = 116, normalized size = 1.1 \begin{align*} -{\frac{1}{5\,f \left ( a+b \right ) \left ( \tan \left ( fx+e \right ) \right ) ^{5}}}-{\frac{{a}^{2}}{f \left ( a+b \right ) ^{3}\tan \left ( fx+e \right ) }}-{\frac{b}{3\,f \left ( a+b \right ) ^{2} \left ( \tan \left ( fx+e \right ) \right ) ^{3}}}-{\frac{2\,a}{3\,f \left ( a+b \right ) ^{2} \left ( \tan \left ( fx+e \right ) \right ) ^{3}}}-{\frac{{a}^{2}b}{f \left ( a+b \right ) ^{3}}\arctan \left ({\tan \left ( fx+e \right ) b{\frac{1}{\sqrt{ \left ( a+b \right ) b}}}} \right ){\frac{1}{\sqrt{ \left ( a+b \right ) b}}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 0.606366, size = 1397, normalized size = 13.3 \begin{align*} \left [-\frac{4 \,{\left (8 \, a^{2} - 9 \, a b - 2 \, b^{2}\right )} \cos \left (f x + e\right )^{5} - 20 \,{\left (4 \, a^{2} - 3 \, a b - b^{2}\right )} \cos \left (f x + e\right )^{3} - 15 \,{\left (a^{2} \cos \left (f x + e\right )^{4} - 2 \, a^{2} \cos \left (f x + e\right )^{2} + a^{2}\right )} \sqrt{-\frac{b}{a + b}} \log \left (\frac{{\left (a^{2} + 8 \, a b + 8 \, b^{2}\right )} \cos \left (f x + e\right )^{4} - 2 \,{\left (3 \, a b + 4 \, b^{2}\right )} \cos \left (f x + e\right )^{2} + 4 \,{\left ({\left (a^{2} + 3 \, a b + 2 \, b^{2}\right )} \cos \left (f x + e\right )^{3} -{\left (a b + b^{2}\right )} \cos \left (f x + e\right )\right )} \sqrt{-\frac{b}{a + b}} \sin \left (f x + e\right ) + b^{2}}{a^{2} \cos \left (f x + e\right )^{4} + 2 \, a b \cos \left (f x + e\right )^{2} + b^{2}}\right ) \sin \left (f x + e\right ) + 60 \, a^{2} \cos \left (f x + e\right )}{60 \,{\left ({\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f \cos \left (f x + e\right )^{4} - 2 \,{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f \cos \left (f x + e\right )^{2} +{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f\right )} \sin \left (f x + e\right )}, -\frac{2 \,{\left (8 \, a^{2} - 9 \, a b - 2 \, b^{2}\right )} \cos \left (f x + e\right )^{5} - 10 \,{\left (4 \, a^{2} - 3 \, a b - b^{2}\right )} \cos \left (f x + e\right )^{3} - 15 \,{\left (a^{2} \cos \left (f x + e\right )^{4} - 2 \, a^{2} \cos \left (f x + e\right )^{2} + a^{2}\right )} \sqrt{\frac{b}{a + b}} \arctan \left (\frac{{\left ({\left (a + 2 \, b\right )} \cos \left (f x + e\right )^{2} - b\right )} \sqrt{\frac{b}{a + b}}}{2 \, b \cos \left (f x + e\right ) \sin \left (f x + e\right )}\right ) \sin \left (f x + e\right ) + 30 \, a^{2} \cos \left (f x + e\right )}{30 \,{\left ({\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f \cos \left (f x + e\right )^{4} - 2 \,{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f \cos \left (f x + e\right )^{2} +{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} f\right )} \sin \left (f x + e\right )}\right ] \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.32298, size = 243, normalized size = 2.31 \begin{align*} -\frac{\frac{15 \,{\left (\pi \left \lfloor \frac{f x + e}{\pi } + \frac{1}{2} \right \rfloor \mathrm{sgn}\left (b\right ) + \arctan \left (\frac{b \tan \left (f x + e\right )}{\sqrt{a b + b^{2}}}\right )\right )} a^{2} b}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \sqrt{a b + b^{2}}} + \frac{15 \, a^{2} \tan \left (f x + e\right )^{4} + 10 \, a^{2} \tan \left (f x + e\right )^{2} + 15 \, a b \tan \left (f x + e\right )^{2} + 5 \, b^{2} \tan \left (f x + e\right )^{2} + 3 \, a^{2} + 6 \, a b + 3 \, b^{2}}{{\left (a^{3} + 3 \, a^{2} b + 3 \, a b^{2} + b^{3}\right )} \tan \left (f x + e\right )^{5}}}{15 \, f} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]